package com.woniu.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.woniu.pojo.User;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 * 会员表 Mapper 接口
 * </p>
 *
 * @author xiaotang
 * @since 2023-07-20
 */
public interface UserMapper extends BaseMapper<User> {

    @Select("select * from wnxt_user where username = #{username} and is_deleted = 0")
    User getByUsername(String username);

    @Select("select * from wnxt_user where mobile = #{mobile} or username = #{mobile}")
    User getUserByMobile(String mobile);
}